<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

<html>
<head>
<title>ASAA-GGC</title>
<style type="text/css">@import"style.css";</style>
<link rel="stylesheet" href="gray.css" type="text/css" title="gray">
<link rel="alternate stylesheet" type="text/css" href="red.css" title="red">
<link rel="alternate stylesheet" type="text/css" href="blue.css" title="blue">
<link rel="alternate stylesheet" type="text/css" href="orange.css" title="orange">
<script type="text/javascript" src="styleswitcher.js"></script>
<script language="JavaScript" type="text/JavaScript">
        <!--

function textCounter(field,cntfield,maxlimit) {
if (field.value.length > maxlimit)
field.value = field.value.substring(0, maxlimit);
// otherwise, update 'characters left' counter
else
cntfield.value = maxlimit - field.value.length;
}

//--> </script>
<script language="JavaScript" type="text/JavaScript">
<!--
function validate(form) {  

if (form.gname.value==""){
alert("Please fill in your group name");
form.gname.focus();
}
else if(form.description.value==""){
alert("Please fill in a description of your group");
form.description.focus();
}
else if (form.fname.value==""){
alert("Please fill in your first name");
form.fname.focus();
}
else if(form.lname.value==""){
alert("Please fill in your last name");
form.lname.focus();
}
else if (form.email.value == "")
{
window.alert("Please enter your e-mail address.");
form.email.focus();

}else if (form.email.value.indexOf("@", 0) < 0)
{
window.alert("Please enter a valid e-mail address(example@domain.com).");
form.email.focus();

}else if (form.email.value.indexOf(".", 0) < 0)
{
window.alert("Please enter a valid e-mail address(example@domain.com).");
form.email.focus();
}
else{
form.submit();
}
}
//-->
</script>
</head>


<body>
<div class="main">

<div class="header">


            <h2></h2>


                    <ul>
                            <li> <a href="index.jsp">Home</a> </li>
                            <li> <a href="#">My Profile</a> </li>
                            <li> <a href="#">My Calendar</a> </li>
                            <li> <a href="myGroup.jsp">My Groups</a> </li>
                    </ul>


</div>


<div id="content">

<h3>WELCOME, Scott! (<a href="#">Logout</a>)
<div id="colorchange">
            <ul>
                    <li><a href="#" onclick="setActiveStyleSheet('gray'); return false;" title="Gray Theme"><img src="images/btngray.gif" alt="Gray Theme" /></a></li>
                    <li><a href="#" onclick="setActiveStyleSheet('red'); return false;" title="Red Theme"><img src="images/btnred.gif" alt="Red Theme" /></a></li>
                    <li><a href="#" onclick="setActiveStyleSheet('blue'); return false;" title="Blue Theme"><img src="images/btnblue.gif" alt="Blue Theme" /></a></li>
                    <li><a href="#" onclick="setActiveStyleSheet('orange'); return false;" title="Organe Theme"><img src="images/btnorange.gif" alt="Orange Theme" /></a></li>
            </ul>
            </div></h3>

<h4>Create Group</h4>
<form name="addgroup" action="verifygroup.jsp" method="post">
<p>
<strong>Group Name</strong>
</p>
<p>This name will appear on your Group page and in search results. </p>
<p>
<input type="text" name="gname">
</p>

<p>
<strong>Describe Your Group</strong>
</p>

<p>This description will appear at the top of your Group page.</p>

<p><textarea name="description" cols="50" rows="10"
             onKeyDown="textCounter(document.addgroup.description,document.addgroup.textcount,500)"
         onKeyUp="textCounter(document.addgroup.description,document.addgroup.textcount,500)"></textarea></p>
<p><input readonly type="text" name="textcount" size="4" maxlength="4" value="500">
characters left, 500 max</p>
<p>This information will appear on your Group page as the Group's Administrator. 
</p>
<p> <strong>First Name:</strong> 
<input type="text" name="fname">
</p>
<p> <strong>Last Name:</strong> 
<input type="text" name="lname">
</p>
<p> <strong>Email:</strong> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<input type="text" name="email">
</p>
<p> <input type="button" value="Continue" onclick="validate(this.form)"></p>
</form>

</div>

</div>

<div id="footer">
<ul>
<li><a href="index.jsp">Home</a> |  </li>
<li><a href="#">My Profile</a>|  </li>
<li><a href="#">My Calendar</a>|  </li>
<li><a href="myGroup.jsp">My Groups</a>|  </li>
<li><a href="#">Help</a></li>
</ul>
<p>Created by Yosemit - UGA MIT Students</p>
</div>

</body>
</html>
